package com.designpatterns.decorator;

/**
 * @author Jack
 * @description: 装饰器扩展
 * @date 2021/10/14 14:07
 */
public class RedShapDecorator extends ShapDecorator {
    public RedShapDecorator(Shape shape) {
        super(shape);
    }

    @Override
    public void draw() {
        shapeDecorator.draw();
        this.setRedBorder(shapeDecorator);
    }

    private void setRedBorder(Shape shape){
        System.out.println("添加红色边框");

    }

}
